package com.smile.spring.service;

import java.beans.PropertyEditor;
import java.beans.PropertyEditorSupport;

/**
 * @author LiYuhang
 * @version 0.1
 * @application
 * @Copyright 上海申通快递总部
 * @company STO
 * @Date 2021/12/12 19:27
 */
public class StringToUserPropertyEditor  extends PropertyEditorSupport implements PropertyEditor {
    @Override
    public void setAsText(String text) throws IllegalArgumentException {
        User user = new User();
        user.setName(text);
        this.setValue(user);
    }
}
